//
//  WBWebViewController.swift
//  新浪微博
//
//  Created by 名品导购网MPLife.com on 2017/12/14.
//  Copyright © 2017年 sweet. All rights reserved.
//

import UIKit
//WBBaseViewController
class WBWebViewController: WBBaseViewController {
private lazy var webView = UIWebView(frame: UIScreen.main.bounds)
    var urlString:String?{
        didSet{
            
            guard  let urlStr = urlString,let url = URL(string: urlStr) else {
                return
            }
            webView .loadRequest(URLRequest(url: url))
            
        }
    }
    
    override func viewDidLoad() {
        super.viewDidLoad()

    }
}
extension WBWebViewController{
    override func setUpTableView() {
        navItem.title = "网页"
        //设置webView
        view.insertSubview(webView, belowSubview: navigationBar)
        webView.backgroundColor = UIColor.white
        //设置contentInset
        webView.scrollView.contentInset.top  = navigationBar.bounds.height-20
    }
}









